home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 20 / Cream of the Crop 20 (Terry Blount) (1996).iso / program / n_b_v203.zip / REMOVE.DMO < prev    next >
Text File  |  1996-07-04  |  2KB  |  51 lines

  1. $if 0
  2.     ┌──────────────────────────╖                        PowerBASIC v3.20
  3.  ┌──┤          DASoft          ╟──────────────────────┬──────────────────╖
  4.  │  ├──────────────────────────╢    Copyright 1995    │ DATE: 1995-10-01 ╟─╖
  5.  │  │ FILE NAME   REMOVE  .DMO ║          by          ╘════════════════─ ║ ║
  6.  │  │                          ║  Don Schullian, Jr.                     ║ ║
  7.  │  ╘══════════════════════════╝                                         ║ ║
  8.  │ A license is hereby granted to the holder to use this source code in  ║ ║
  9.  │ any program, commercial or otherwise,  without receiving the express  ║ ║
  10.  │ permission of the copyright holder and without paying any royalties,  ║ ║
  11.  │ as long as this code is not distributed in any compilable format.     ║ ║
  12.  │  IE: source code files, PowerBASIC Unit files, and printed listings   ║ ║
  13.  ╘═╤═════════════════════════════════════════════════════════════════════╝ ║
  14.    │                ....................................                   ║
  15.    ╘═══════════════════════════════════════════════════════════════════════╝
  16. $endif
  17.  
  18. '.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°.°
  19. ' ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° ° °
  20.  
  21. $INCLUDE "DAS-NB01.INC"
  22. COLOR 7, 0
  23. CLS
  24.  
  25. ? "┌────────────────────────────────────────────────────────────
  26. ? "│ fREMOVEmid$( ANY, MidPos%, HowMany% )
  27. ? "├────────────────────────────────────────────────────────────────
  28. ? "│ Just like the sign says... it removes a MID$ from an existing
  29. ? "│ string.
  30. ? "└─────────────────────────────────────────────────────────────────────────
  31.  
  32. MAP V$$ * 10
  33. V$$ = "1234567890"
  34.  
  35. PRINT "SHOULD BE: 1567890<<"
  36. PRINT "─────────> "; fREMOVEmid$( V$$,  2,  3 ); "<<"
  37. PRINT
  38. PRINT "SHOULD BE: 1234567890<<"
  39. PRINT "─────────> "; fREMOVEmid$( V$$, 11,  3 ); "<<"
  40. PRINT
  41. PRINT "SHOULD BE: <<"
  42. PRINT "─────────> "; fREMOVEmid$( V$$,  1, 18 ); "<<"
  43. PRINT
  44. PRINT "SHOULD BE: 90<<"
  45. PRINT "─────────> "; fREMOVEmid$( V$$,  1,  8 ); "<<"
  46. PRINT
  47. PRINT "SHOULD BE: 234567890 <<"
  48.       V$$ = fREMOVEmid$( V$$, 1, 1 )
  49. PRINT "─────────> "; V$$; "<<"
  50.  
  51.